#ifndef MOUSEINPUT_H
#define MOUSEINPUT_H
#include "StompedReality/Math/Vector2.h"
namespace StompedReality
{
namespace Input
{
/*!
 * \author	Stefan Kazalski
 *
 * \brief	Mouse input.
 */
class MouseInput {
 protected:

  StompedReality::Math::Vector2 m_PrevPostion;
  StompedReality::Math::Vector2 m_CurrentPostion;
  bool m_CurrentLeft;
  bool m_PrevLeft;
  bool m_CurrentRight;
  bool m_PrevRight;

 public:

  /*!
   * \brief		Constructor.
   */
  MouseInput( );

  /*!
   * \brief		Destructor.
   */
  virtual ~MouseInput( );

  /*!
   * \brief		Current mouse position.
   *
   * \return	The mouse position.
   */
  StompedReality::Math::Vector2 GetPosition( );

  /*!
   * \brief		Current mouse position delta.
   *
   * \return	The mouse position delta.
   */
  StompedReality::Math::Vector2 GetPositionDelta( );

  /*!
   * \brief		Is left mouse button down.
   *
   * \return	True if left mouse button is down otherwise false.
   */
  bool IsLeftButtonDown( );

  /*!
   * \brief		Is left mouse button pressed.
   *
   * \return	True if left mouse button is pressed otherwise false.
   */
  bool IsLeftButtonPressed( );

  /*!
   * \brief		Is left mouse button up.
   *
   * \return	True if left mouse button is up otherwise false.
   */
  bool IsLeftButtonUp( );

  /*!
   * \brief		Is right mouse button down.
   *
   * \return	True if right mouse button is down otherwise false.
   */
  bool IsRightButtonDown( );

  /*!
   * \brief		Is right mouse button pressed.
   *
   * \return	True if right mouse button is pressed otherwise false.
   */
  bool IsRightButtonPressed( );

  /*!
   * \brief		Is right mouse button up.
   *
   * \return	True if right mouse up is down otherwise false.
   */
  bool IsRightButtonUp( );

  /*!
   * \brief		Updates mouse button.
   *
   * \param		newPos	New mouse position.
   */
  void UpdatePosition( StompedReality::Math::Vector2* newPos );

  /*!
   * \brief		Updates mouse button.
   *
   * \param		left	New left button state.
   * \param		right	New right button state.
   */
  void UpdateButtons( char* left, char* right );
};

}
}
#endif // ifndef MOUSEINPUT_H